cmake_minimum_required(VERSION 3.12)

project (MeshSubdivision)

option(USE_DOUBLE_PRECISION "whether use double precision" ON)
if (USE_DOUBLE_PRECISION)
    set(SCALAR_TYPE double)
else()
    set(SCALAR_TYPE float)
endif()

configure_file(Config.h.in ${CMAKE_CURRENT_SOURCE_DIR}/common/Config.h)

set(CMAKE_CXX_STANDARD 17)
set(CMAKE_DEBUG_POSTFIX "d")

if (MSVC)
    add_definitions(-utf-8)
endif()

add_compile_definitions(NOMINMAX)
add_compile_definitions(_CRT_SECURE_NO_WARNINGS)

add_subdirectory(src)